#!/usr/bin/env python

class DataSource(object):
	"""Abstract class referencing a data source.
	A data source is a single array of values associated with one set of metadata."""
	def __init__(self, etag=None):
		# The HTTP etag/md5sum/lastModifDate of the DAP file during the last update
		self.etag = etag
		
	def getMetaData(self):
		"""Return the key:(value, comment) dictionary containing 
		all the metadata associated with this DataSource."""
		raise NotImplementedError
		
	def getData(self, slice=None):
		"""Return the numpy array of this DataSource or a slice of it"""
		raise NotImplementedError
		
	def getDataType(self):
		"""Return the numpy array type for this DataResource"""
		raise NotImplementedError
		
	def getDataShape(self):
		"""Return the numpy array shape for this DataResource"""
		raise NotImplementedError